package com.example.demo.fruits.strategy;


public class Context implements DisCountStrategy{

    private DisCountStrategy disCountStrategy;

    public Context(DisCountStrategy disCountStrategy){
        this.disCountStrategy=disCountStrategy;
    }

    @Override
    public double cost(double totalPrice) {
        return disCountStrategy.cost(totalPrice);
    }
}
